package com.xinyue.game.common;

/**
 * @Author 王广帅
 * @Date 2020/12/26 18:50
 */
public class SystemContext {

    private static long offsetMillTime;//时间偏移量，用于调时间
    private static String namespace = "dev";//命名空间，用于隔离相同配置下的不同运行环境

    public static String getNamespace() {
        return namespace;
    }

    public static void setNamespace(String namespace) {
        SystemContext.namespace = namespace;
    }

    public static void setOffsetMillTime(long offsetMillTime) {
        SystemContext.offsetMillTime = offsetMillTime;
    }

    public static long getCurrentMillTime() {
        return System.currentTimeMillis() + offsetMillTime;
    }
}
